package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.entity.NursingLevel;
import com.zzyl.vo.NurLeUpdateVo;
import com.zzyl.vo.NursingLevelVo;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface NursingLevelMapper {

    List<NursingLevelVo> listAll();

    void addLevel(NursingLevel nursingLevel);

    Page<NursingLevelVo> list(String name, Integer status);

    NursingLevelVo getById(Long id);

    @Update("update nursing_level set status = #{status} where id = #{id}")
    void disableById(Long id, Integer status);


    @Delete("delete from nursing_level where id = #{id}")
    void deleteById(Long id);


    void updateNL(NurLeUpdateVo nursingLevel);

    Integer getCount(Long id);
}
